<template>
  <el-form style="width: 40%" :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">

    <el-form-item label="学号">
      <el-input v-model="ruleForm.id" readonly></el-input>
    </el-form-item>
    <el-form-item label="姓名" prop="name">
      <el-input v-model="ruleForm.name" readonly></el-input>
    </el-form-item>
    <el-form-item label="性别" prop="nex">
      <el-input v-model="ruleForm.nex" readonly></el-input>
    </el-form-item>
    <el-form-item label="系别" prop="step">
      <el-input v-model="ruleForm.step" readonly></el-input>
    </el-form-item>
    <el-form-item label="年龄" prop="age">
      <el-input v-model="ruleForm.age" readonly></el-input>
    </el-form-item>
    <el-form-item label="身高" prop="high">
      <el-input v-model="ruleForm.high" readonly></el-input>
    </el-form-item>
    <el-form-item label="体重" prop="weight">
      <el-input v-model="ruleForm.weight" readonly></el-input>
    </el-form-item>
    <el-form-item label="胸围" prop="xwei">
      <el-input v-model="ruleForm.xwei" readonly></el-input>
    </el-form-item>
    <el-form-item label="日期" prop="data">
      <el-input v-model="ruleForm.data" readonly></el-input>
    </el-form-item>
  </el-form>
</template>

<script>
export default {
  data() {
    return {
      ruleForm: {
        id: '',
        name: '',
        nex: '',
        step: '',
        age: '',
        high: '',
        weight: '',
        xwei: '',
        data: ''
      },
      rules: {
      }
    };
  },
  methods: {

  },
  created(){
    const _this = this
    axios.get('http://localhost:8181/book/findById/'+this.$route.query.id).then(function (resp) {
      _this.ruleForm = resp.data
    })
  }
}
</script>
